<?php
/**
 * Created by PhpStorm.
 * User: MF
 * Date: 2017/6/5
 * Time: 22:42
 */

if (!function_exists('user')) {
	/**
	 * @param null $driver
	 * @return mixed
	 */
	function user($driver = null)
	{
		if ($driver) {
			return app('auth')->guard($driver)->user();
		}
		return app('auth')->user();
	}
}